<template>
    <div class="notPushedOrder">
        <el-breadcrumb separator="/" class="bread-title">
            <el-breadcrumb-item>配置中心</el-breadcrumb-item>
            <el-breadcrumb-item>金蝶对接</el-breadcrumb-item>
            <el-breadcrumb-item>未推送订单池</el-breadcrumb-item>
        </el-breadcrumb>
        <el-table :data="tableData" border>
            <el-table-column type="index" label="序号" width="50"></el-table-column>
            <el-table-column prop="orderId" label="订单号"></el-table-column>
            <el-table-column prop="devName" label="楼盘"></el-table-column>
            <el-table-column prop="recordTime" label="订单时间(认购/收款)">
                <template slot-scope="scope">
                    <TimeComp :timestamp="scope.row.recordTime"></TimeComp>
                </template>
            </el-table-column>
            <el-table-column prop="type" label="类型">
                <template slot-scope="scope">
                    {{scope.row.type == '1' ? '交易及佣金': ''}}
                    {{scope.row.type == '2' ? '交易及佣金驳回': ''}}
                    {{scope.row.type == '3' ? '回款': ''}}
                    {{scope.row.type == '4' ? '支付': ''}}
                </template>
            </el-table-column>
            <el-table-column prop="pushStatus" label="推送状态"></el-table-column>
            <el-table-column prop="reason" label="原因"></el-table-column>
            <el-table-column prop="" label="推送金蝶组织名称"></el-table-column>
            <el-table-column prop="" label="推送金蝶组织ID"></el-table-column>
        </el-table>
        <div class="pagebar">
            <el-pagination
                    background
                    layout="total, sizes, prev, pager, next"
                    :current-page.sync="currentPage"
                    :page-sizes="[10, 20, 30, 40]"
                    :page-size="pageSize"
                    @size-change="handleSizeChange"
                    @current-change="handleCurrentChange"
                    :total="totalSize">
            </el-pagination>
        </div>
    </div>
</template>

<script>

import TimeComp from '@/components/common/timeComp'
export default {
    name:"notPushedOrder",
    title:'未推送订单池',
    components: {TimeComp},
    created() {
        this.searchList()
    },
    actiaved(){
        this.searchList()
    },
    mounted() {},
    data() {
        return {
            tableData: [],
            currentPage: 1,
            pageSize: 10,
            totalSize: 0
        }
    },
    methods: {
        searchList () {
            let param = {}
            param.pageNum = this.currentPage
            param.pageSize = this.pageSize
            this.$axios.post('/kingdee/manage/noPushListPage', param).then(res => {
                this.tableData = res.list
                this.totalSize = res.total
            })
        },
        // 分页器改变页码
        handleCurrentChange () {
            this.searchList()
        },
        handleSizeChange (val) {
            this.pageSize = val
            this.searchList()
        },
    },
    computed: {},
}
</script>
<style lang="stylus" scoped>
    .notPushedOrder {

    }
</style>
